package main

/*
 * @Auhtor: wali
 * @Date: 2020-12-09 14:29:48
 * @LastEditors: wali QQ:36646643
 * @LastEditTime: 2020-12-09 14:34:12
 * @Description: video-cms
 */

import "fmt"

type rect struct { // 定义一个结构体
	width  int
	height int
}

func (r *rect) area() int {
	return r.width * r.height
}

func main() {

	r := rect{10, 15} // 初始化
	fmt.Print(r.area())
}
